import constants
from celery_tasks.main import app
from libs.yuntongxun.sms import CCP


@app.task(name='send_sms_code')
def send_sms_code(mobile, smscode):
    ccp = CCP()
    ccp.send_template_sms(mobile, [smscode, constants.SMS_CODE_REDIS_EXPIRES], 1)
